﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Exhibition.Dao.ViewModel;
using Exhibition.Service;

namespace Exhibition.control
{
    public partial class Foot : BaseControl
    {
        StringBuilder sb = new StringBuilder();

        protected void Page_Load(object sender, EventArgs e)
        {
            GetFrindLink();
            //CenterService.frindLinkService.GetList();
        }

        public void GetFrindLink(){
            if(stmd!=null){
               List<FrindLinkModel> fmdls= CenterService.frindLinkService.GetFrindLink(stmd.Id);
               if (fmdls != null) {
                   foreach (var s in fmdls) {
                       sb.AppendFormat("<a href='{0}' target='_blank'>{1}</a>",s.SiteUrl,s.SiteName);
                   }
               }
               ltrLink.Text = sb.ToString();

            }
        }

    }
}